package com.will.txj.aj.security.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.will.txj.aj.security.mapper.SysRoleMapper;
import com.will.txj.aj.security.service.ISysRoleService;
import com.will.txj.common.security.SysRole;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import javax.annotation.Resource;
import java.util.List;

/**
 * <p>
 *  服务实现类
 * </p>
 *
 * @author wen-yi
 * @since 2021-11-26
 */
@Service
@Transactional
public class SysRoleServiceImpl extends ServiceImpl<SysRoleMapper, SysRole> implements ISysRoleService {
    @Resource
    private SysRoleMapper sysRoleMapper;

    @Override
    @Transactional(readOnly = true)
    public List<SysRole> getRoleListByUsername(String username) {
        return sysRoleMapper.getRoleListByUsername(username);
    }
}
